Repository navigation
audio: cadence: support RAW AAC decoding and support for DIF and MPEG-2 ADTS with IPC4 - #11451
Merged
lgirdwood merged 2 commits intoNov 13, 2026
Merged
Conversation
ujfalusi
requested review from
dbaluta,
kv2019i,
lbetlej,
lgirdwood,
mmaka1 and
plbossart
as code owners
November 12, 2026 16:50
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
RAW AAC initialization and drain correctness depend on Cadence runtime behavior unavailable in this snapshot, requiring broader DUT validation of short/empty streams, partial blocks, repeated flushes, stereo, and IPC4/library input-size mismatches.
No open issues 🎉
What changed in this PR
Adds RAW AAC decoding to the IPC4 Cadence adapter alongside existing MPEG-4 ADTS support, including handling for zero-filled padding during drain.
Changes:
- Selects the Cadence bitstream format explicitly for RAW or ADTS input.
- Configures RAW input’s external sample rate and stereo output from codec parameters.
- Submits zero input bytes for all-zero RAW AAC buffers when end-of-stream is expected.
| File | Description |
|---|---|
src/audio/module_adapter/module/cadence_ipc4.c |
Adds RAW AAC configuration and drain-padding detection. |
Review effort: Balanced
lgirdwood
approved these changes
Nov 12, 2026
PR 11451: test resultsRun date: 2026-11-13 09:14 UTC Tested commit: 7d2818df6343427405ab8a20a5931d9dadef20e5 |
ujfalusi
force-pushed
the
peter/pr/compress-aac-raw
branch
from
November 13, 2026 06:50
7d2818d to
d61093c
Compare
Accept RAW AAC alongside MPEG-4 ADTS and select the Cadence bitstream format explicitly. Configure the external sample rate and stereo output selection from the codec parameters for RAW input. During drain, the host can supply zero-filled padding after the last AAC payload. Passing this padding to the RAW decoder causes a fatal error before the existing EOS detection can run. Supply zero input bytes for all-zero RAW AAC buffers when EOS is expected, allowing the decoder to flush its remaining output and complete drain. Validated with a signed PTL build and mocked EOS regression tests. DUT testing confirmed AAC LC M4A playback at 24 kHz mono and 48 kHz stereo, with drain completion verified for the 24 kHz mono stream. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Map ADIF to the Cadence AAC ADIF bitstream mode and accept MPEG-2 ADTS using the ADTS parser. The decoder parses the MPEG ID from the ADTS stream; MPEG_ID and ORIGINAL_OR_COPY are decoder-reported values, not configuration parameters.
kv2019i
approved these changes
Nov 13, 2026
kv2019i
left a comment
Collaborator
There was a problem hiding this comment.
Tested on Intel PTL system using fcplay from https://github.com/ujfalusi/tinycompress/commits/peter/wip/
lgirdwood
approved these changes
Nov 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Accept RAW AAC alongside MPEG-4 ADTS and select the Cadence bitstream format explicitly. Configure the external sample rate and stereo output selection from the codec parameters for RAW input.
During drain, the host can supply zero-filled padding after the last AAC payload. Passing this padding to the RAW decoder causes a fatal error before the existing EOS detection can run. Supply zero input bytes for all-zero RAW AAC buffers when EOS is expected, allowing the decoder to flush its remaining output and complete drain.
Validated with a signed PTL build and mocked EOS regression tests. DUT testing confirmed AAC LC M4A playback at 24 kHz mono and 48 kHz stereo, with drain completion verified for the 24 kHz mono stream.